A = 0;
B = 0;
C = 0;

%%
%1
len = 4 + A + B + C;
b = ((1+A*C).*(1:len) - (1+B:len+B).^2 ./ (2+A))'
%%

%%
%2
len = 4 + A + B + C;
FUN = @(x) exp(x);
M = repmat([1:len], len, 1);
M = A .* M + B .* M';
M = FUN(M) + (rand(len, len) .* (2 + A + B) - 1 - A)
L = len
C = FUN(0)
%%

%%
%3
eps = 0.00001;
det(M)
if abs(det(M)) > eps
    'Матрица невырождена'
else
    'матрица вырождена'
end
%%

%%
%4
x = inv(M) * b
%%

%%
%5
t = 10 + A^2 + B^2 + (C+1)^A;
options = odeset('RelTol',1e-4,'AbsTol',[1e-4 1e-4 1e-5]);
[T, Y] = ode45(@f, [0,t], [0.1,0.1,0.1], options);
%%

%%
%6
figure(1);
plot(Y(:,1), Y(:,2), 'LineWidth', 3)
xlabel('y_1');
ylabel('y_2');
title('2D Phase plane')
%%

%%
%7
figure(2);
plot3(Y(:,1), Y(:,2), Y(:,3), 'LineWidth', 3)
xlabel('y_1');
ylabel('y_2');
zlabel('y_3');
title('3D Phase plane')
%%